export type propStrValueAnyType = {
  [prop: string]: any;
};

type baseResultType = {
  code: number;
  message: string;
};
export type requestResultType = baseResultType & {
  data: {
    [key: string]: any;
  };
};

export type userInfoType = {
  user: string;
  username: string;
  companyId: string;
  companyName: string;
  phone: string;
  provinceId: string;
  cityId: string;
  areaId: string;
  authorities: string;
};

export type userInfoResultType = baseResultType & {
  data: userInfoType;
};

type areaType = {
  id: string;
  name: string;
};

type cityAreaType = areaType & {
  area: areaType[];
};

type provinceAreaType = areaType & {
  city: cityAreaType[];
};

export type regionResType = Array<provinceAreaType>;

export type userRangeRegionsListItemType = {
  type: number;
  provinceId: string;
  cityId: string;
  areaId: string | null;
  provinceName: string;
  cityName: string | null;
  areaName: string | null;
};

export type userRangeRegionsDataType = {
  isNationwide: 1 | 0;
  list: userRangeRegionsListItemType[];
};

export type userRangeRegionsResType = baseResultType & {
  data: userRangeRegionsDataType;
};

export type publicityListType = Array<{
  id: number;
  title: string;
  description: string;
  createDate: string;
  type: number;
}>;
export type publicityListResultType = {
  totla: number;
  list: publicityListType;
};

export type healthStatisticsType = {
  updateDate: string;
  healthEducation: {
    //健康教育
    targetNum: number; //目标
    participatedNum: number; //已参加
  };
  medicationManagement: {
    //用药管理
    targetNum: number; //目标
    participatedNum: number; //已参加
  };
  illnessInsurance: {
    //大病保障
    targetNum: number; //目标
    participatedNum: number; //已参加
  };
};

export type basicUserQueryType = {
  provinceId?: string;
  cityId?: string;
  areaId?: string;
};
